﻿using System;
using System.Collections.Generic;
using System.Linq;
using System.Web;
using System.Web.Mvc;

namespace WebUI.Controllers
{
    [HandleError(View = "Error")]
    public class HomeController : _SiteBaseController
    {
        [Authorize]
        public ActionResult Index()
        {
            if (User.IsInRole("Admin") || User.IsInRole("Engineer")) return RedirectToAction(string.Empty, "SystemMgr");
            if (User.IsInRole("Doctor")) return RedirectToAction(string.Empty, "Doctor");
            if (User.IsInRole("Recuper")) return RedirectToAction(string.Empty, "Recuper");
            return Content("错误的用户。");
        }

        public ActionResult SliderViewPage()
        {
            return View();
        }
        public ActionResult SliderView()
        {
            return PartialView();
        }
    }
}
